package cn.qiguai.sphapi.controller.request;

import lombok.Getter;
import lombok.Setter;

import javax.validation.constraints.NotNull;
import java.util.List;
import java.util.UUID;

/**
 * 提交商品订单接口参数
 */
@Getter
@Setter
public class CommitPayOrderParam {
	private int id;								//购买订单id，用于获取主键自增id
	@NotNull
	private Integer userId;						//用户id
	private String number;						//订单号。由uuid生成
	@NotNull
	private List<Integer> shoppingCartOrderIds;	//商品列表
	@NotNull
	private int addresseeId;					//收件人id
	@NotNull
	private double totalMoney;					//总金额

	public CommitPayOrderParam() {
		number = UUID.randomUUID().toString().replaceAll("-", "");
	}
}
